/**
 * 作者：刘时明
 * 时间：2021/4/9
 */
package com.yidu.manage.controller.base;

import com.yidu.common.utils.ResultUtil;
import com.yidu.manage.domain.internal.Server;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;


@RestController
@RequestMapping("/monitor/server")
public class ServerController
{
    @PreAuthorize("@ss.hasPermit('monitor:server:list')")
    @GetMapping()
    public Object getInfo() throws Exception
    {
        Server server = new Server();
        server.copyTo();
        return ResultUtil.success(server);
    }
}
